/*
 * Common define of private data for XRadio drivers
 *
 * Copyright (c) 2013
 * Xradio Technology Co., Ltd. <www.xradiotech.com>
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
 */
#ifndef VENDOR_H
#define VENDOR_H

#define XRADIO_NL80211_VENDOR_ID	0x001374
#define XRADIO_NL80211_ANDROID_ID	0x001A11

enum nl80211_vendor_subcmds {
	NL80211_VENDOR_SUBCMD_DO_ACS = 54,
	NL80211_VENDOR_SUBCMD_GET_FEATURES = 55,
};

enum wlan_vendor_features {
	WLAN_VENDOR_FEATURE_KEY_MGMT_OFFLOAD	= 0,
	WLAN_VENDOR_FEATURE_SUPPORT_HW_MODE_ANY     = 1,
	WLAN_VENDOR_FEATURE_OFFCHANNEL_SIMULTANEOUS = 2,
	WLAN_VENDOR_FEATURE_P2P_LISTEN_OFFLOAD	= 3,
	WLAN_VENDOR_FEATURE_OCE_STA                 = 4,
	WLAN_VENDOR_FEATURE_OCE_AP                  = 5,
	WLAN_VENDOR_FEATURE_OCE_STA_CFON            = 6,
	WLAN_VENDOR_FEATURE_SELF_MANAGED_REGULATORY = 7,
	WLAN_VENDOR_FEATURE_TWT 			= 8,
	NUM_WLAN_VENDOR_FEATURES /* keep last */
};

enum wlan_vendor_attr_acs_offload {
	WLAN_VENDOR_ATTR_ACS_CHANNEL_INVALID = 0,
	WLAN_VENDOR_ATTR_ACS_PRIMARY_CHANNEL,
	WLAN_VENDOR_ATTR_ACS_SECONDARY_CHANNEL,
	WLAN_VENDOR_ATTR_ACS_HW_MODE,
	WLAN_VENDOR_ATTR_ACS_HT_ENABLED,
	WLAN_VENDOR_ATTR_ACS_HT40_ENABLED,
	WLAN_VENDOR_ATTR_ACS_VHT_ENABLED,
	WLAN_VENDOR_ATTR_ACS_CHWIDTH,
	WLAN_VENDOR_ATTR_ACS_CH_LIST,
	WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_CHANNEL,
	WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_CHANNEL,
	WLAN_VENDOR_ATTR_ACS_FREQ_LIST,
	/* keep last */
	WLAN_VENDOR_ATTR_ACS_AFTER_LAST,
	WLAN_VENDOR_ATTR_ACS_MAX =
	WLAN_VENDOR_ATTR_ACS_AFTER_LAST - 1

};

enum wlan_vendor_attr {
	/* used by NL80211_VENDOR_SUBCMD_GET_FEATURES */
	WLAN_VENDOR_ATTR_FEATURE_FLAGS = 7,
};

enum nl80211_android_vendor_subcmds {
	NL80211_WIFI_OFFLOAD_SUBCMD_START_MKEEP_ALIVE = 0x1600,
	NL80211_WIFI_OFFLOAD_SUBCMD_STOP_MKEEP_ALIVE,
};

enum mkeep_alive_attributes {
	MKEEP_ALIVE_ATTRIBUTE_ID = 0x1,
	MKEEP_ALIVE_ATTRIBUTE_IP_PKT,
	MKEEP_ALIVE_ATTRIBUTE_IP_PKT_LEN,
	MKEEP_ALIVE_ATTRIBUTE_SRC_MAC_ADDR,
	MKEEP_ALIVE_ATTRIBUTE_DST_MAC_ADDR,
	MKEEP_ALIVE_ATTRIBUTE_PERIOD_MSEC,

	MKEEP_ALIVE_ATTRIBUTE_AFTER_LAST,
	MKEEP_ALIVE_ATTRIBUTE_MAX =
	MKEEP_ALIVE_ATTRIBUTE_AFTER_LAST - 1
};


enum nl80211_vendor_subcmds_index {
	NL80211_VENDOR_SUBCMD_DO_ACS_INDEX,
	NL80211_VENDOR_SUBCMD_GET_FEATURES_INDEX,
	NL80211_WIFI_OFFLOAD_SUBCMD_START_MKEEP_ALIVE_INDEX,
	NL80211_WIFI_OFFLOAD_SUBCMD_STOP_MKEEP_ALIVE_INDEX,
};

void xradio_vendor_close_mkeep_alive(void);

void xradio_vendor_init(struct wiphy *wiphy);

#endif
